package com.ruoyi.wm.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.wm.mapper.WmDriversMapper;
import com.ruoyi.wm.domain.WmDrivers;
import com.ruoyi.wm.service.IWmDriversService;
import com.ruoyi.common.core.text.Convert;

/**
 * 驾驶员Service业务层处理
 * 
 * @author hpf
 * @date 2021-12-03
 */
@Service
public class WmDriversServiceImpl implements IWmDriversService 
{
    @Autowired
    private WmDriversMapper wmDriversMapper;

    /**
     * 查询驾驶员
     * 
     * @param id 驾驶员ID
     * @return 驾驶员
     */
    @Override
    public WmDrivers selectWmDriversById(Long id)
    {
        return wmDriversMapper.selectWmDriversById(id);
    }

    /**
     * 查询驾驶员列表
     * 
     * @param wmDrivers 驾驶员
     * @return 驾驶员
     */
    @Override
    public List<WmDrivers> selectWmDriversList(WmDrivers wmDrivers)
    {
        return wmDriversMapper.selectWmDriversList(wmDrivers);
    }

    /**
     * 新增驾驶员
     * 
     * @param wmDrivers 驾驶员
     * @return 结果
     */
    @Override
    public int insertWmDrivers(WmDrivers wmDrivers)
    {
        return wmDriversMapper.insertWmDrivers(wmDrivers);
    }

    /**
     * 修改驾驶员
     * 
     * @param wmDrivers 驾驶员
     * @return 结果
     */
    @Override
    public int updateWmDrivers(WmDrivers wmDrivers)
    {
        return wmDriversMapper.updateWmDrivers(wmDrivers);
    }

    /**
     * 删除驾驶员对象
     * 
     * @param ids 需要删除的数据ID
     * @return 结果
     */
    @Override
    public int deleteWmDriversByIds(String ids)
    {
        return wmDriversMapper.deleteWmDriversByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除驾驶员信息
     * 
     * @param id 驾驶员ID
     * @return 结果
     */
    @Override
    public int deleteWmDriversById(Long id)
    {
        return wmDriversMapper.deleteWmDriversById(id);
    }
}
